package com.web_bloks.widget.client;

import com.google.gwt.core.client.GWT;
import com.google.gwt.user.client.ui.AbstractImagePrototype;
import com.google.gwt.user.client.ui.Anchor;
import com.google.gwt.user.client.ui.Image;

/**
 * 
 * @author Jean-Lou Dupont
 *
 */
public class LogoWidget extends Anchor {
	
	Image img = null;
	
	public LogoWidget() {
		super();
		setup();
	}

	private void setup() {
		
		final WidgetMessages MSG = (WidgetMessages) GWT.create(WidgetMessages.class);
		
		WidgetImageBundle bundle = (WidgetImageBundle) GWT.create( WidgetImageBundle.class );
		
		AbstractImagePrototype p = null;
		
		this.setTitle(MSG.logo());

		p = bundle.logo();
		img = p.createImage();	
		
		this.getElement().appendChild(img.getElement());
		
	}

}//END